<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
    <meta name="Content-Type" content="text/html; charset=UTF-8" />
<title>Class: Sass::Engine</title>
<link rel="stylesheet" href="style.css" tppabs="http://sass-lang.com/docs/yardoc/css/style.css" type="text/css" media="screen" charset="utf-8" />
<link rel="stylesheet" href="common.css" tppabs="http://sass-lang.com/docs/yardoc/css/common.css" type="text/css" media="screen" charset="utf-8" />

<script type="text/javascript" charset="utf-8">
  relpath = '..';
  if (relpath != '') relpath += '/';
</script>
<script type="text/javascript" charset="utf-8" src="jquery.js" tppabs="http://sass-lang.com/docs/yardoc/js/jquery.js"></script>
<script type="text/javascript" charset="utf-8" src="app.js" tppabs="http://sass-lang.com/docs/yardoc/js/app.js"></script>

  </head>
  <body>
    <script type="text/javascript" charset="utf-8">
      if (window.top.frames.main) document.body.className = 'frames';
    </script>
    
    <div id="header">
      <div id="menu">
  
    <a href="_index.html" tppabs="http://sass-lang.com/docs/yardoc/_index.html">Index (E)</a> &raquo; 
    <span class='title'><a href="Sass-1.html" tppabs="http://sass-lang.com/docs/yardoc/Sass.html" title="Sass (module)">Sass</a></span>
     &raquo; 
    <span class="title">Engine</span>
  
  
  <div class="noframes"><span class="title">(</span><a href="javascript:if(confirm(%27http://sass-lang.com/docs/yardoc/Sass/.  \n\nThis file was not retrieved by Teleport Pro, because the server reports that this file cannot be found.  \n\nDo you want to open it from the server?%27))window.location=%27http://sass-lang.com/docs/yardoc/Sass/.%27" tppabs="http://sass-lang.com/docs/yardoc/Sass/." target="_top">no frames</a><span class="title">)</span></div>
</div>

      <div id="search">
  <a id="class_list_link" href="#">Class List</a>
  <a id="method_list_link" href="#">Method List</a>
  <a id ="file_list_link" href="#">File List</a>
</div>

      <div class="clear"></div>
    </div>
    
    <iframe id="search_frame"></iframe>
    
    <div id="content"><h1>Class: Sass::Engine 
  
  
</h1>

<dl class="box">
  
    <dt class="r1">Inherits:</dt>
    <dd class="r1">
      <span class="inheritName">Object</span>
      
        <ul class="fullTree">
          <li>Object</li>
          
            <li class="next">Sass::Engine</li>
          
        </ul>
        <a href="#" class="inheritanceTree">show all</a>
      
      </dd>
    
  
  
    
  
    
      <dt class="r2">Includes:</dt>
      <dd class="r2"><a href="Util.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html" title="Sass::Util (module)">Util</a></dd>
      
    
  
  
    <dt class="r1 last">Defined in:</dt>
    <dd class="r1 last">/var/www/sass-pages/.sass/lib/sass/engine.rb</dd>
  
</dl>
<div class="clear"></div>

<h2>Overview</h2><div class="docstring">
  <div class="discussion">
    <p>This class handles the parsing and compilation of the Sass template. Example usage:</p>

<pre class="code">template = File.load(&#39;stylesheets/sassy.sass&#39;)
sass_engine = Sass::Engine.new(template)
output = sass_engine.render
puts output</pre>

  </div>
</div>
<div class="tags">
  
</div>
  <h2>Constant Summary</h2>
  
    <dl class="constants">
      
        <dt id="DEFAULT_OPTIONS-constant" class="">DEFAULT_OPTIONS =
            <span class="summary_desc">The default options for Sass::Engine.</span>
        </dt>
        <dd><pre class="code">{
  :style => :nested,
  :load_paths => ['.'],
  :cache => true,
  :cache_location => './.sass-cache',
  :syntax => :sass,
  :filesystem_importer => Sass::Importers::Filesystem
}.freeze</pre></dd>
      
    </dl>
  


  
  
  
  
  <h3 class="inherited">Constants included from <a href="Util.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html" title="Sass::Util (module)">Util</a></h3>
  <p class="inherited"><a href="Util.html#RUBY_ENGINE-constant" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#RUBY_ENGINE-constant" title="Sass::Util::RUBY_ENGINE (constant)">RUBY_ENGINE</a>, <a href="Util.html#RUBY_VERSION-constant" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#RUBY_VERSION-constant" title="Sass::Util::RUBY_VERSION (constant)">RUBY_VERSION</a></p>

  <h2>Instance Attribute Summary</h2>
  <ul class="summary">
    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#options-instance_method" title="#options (instance method)">- ({Symbol =&gt; Object}) <strong>options</strong> </a>
    

    
  </span>
  
  
    <span class="note title readonly">readonly</span>
    
  
  
  
  

  
    <span class="summary_desc">The options for the Sass engine.</span>
  
</li>

    
  </ul>


  <h2>Class Method Summary</h2>

  <ul class="summary">
    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#for_file-class_method" title="for_file (class method)">+ (Sass::Engine) <strong>for_file</strong>(filename, options) </a>
    

    
  </span>
  
  
  
  
  

  
    <span class="summary_desc">Returns the <tt><a href="" title="Sass::Engine (class)">Sass::Engine</a></tt> for the given file.</span>
  
</li>

    
  </ul>

  <h2>Instance Method Summary</h2>

  <ul class="summary">
    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#dependencies-instance_method" title="#dependencies (instance method)">- ([Sass::Engine]) <strong>dependencies</strong> </a>
    

    
  </span>
  
  
  
  
  

  
    <span class="summary_desc">Gets a set of all the documents that are (transitive) dependencies of this document, not including the document itself.</span>
  
</li>

    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#initialize-instance_method" title="#initialize (instance method)">- (Engine) <strong>initialize</strong>(template, options = {}) </a>
    

    
  </span>
  
    <span class="note title constructor">constructor</span>
  
  
  
  
  

  
    <span class="summary_desc">Creates a new Engine.</span>
  
</li>

    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#render-instance_method" title="#render (instance method)">- (String) <strong>render</strong> </a>
    

    
      (also: #to_css)
    
  </span>
  
  
  
  
  

  
    <span class="summary_desc">Render the template to CSS.</span>
  
</li>

    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#source_encoding-instance_method" title="#source_encoding (instance method)">- (Encoding<sup>?</sup>) <strong>source_encoding</strong> </a>
    

    
  </span>
  
  
  
  
  

  
    <span class="summary_desc">Returns the original encoding of the document, or <code>nil</code> under Ruby 1.8.</span>
  
</li>

    
      <li class="public ">
  <span class="summary_signature">
    
      <a href="#to_tree-instance_method" title="#to_tree (instance method)">- (Sass::Tree::Node) <strong>to_tree</strong> </a>
    

    
  </span>
  
  
  
  
  

  
    <span class="summary_desc">Parses the document into its parse tree.</span>
  
</li>

    
  </ul>

  
  
  
  
  
  <h3 class="inherited">Methods included from <a href="Util.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html" title="Sass::Util (module)">Util</a></h3>
  <p class="inherited"><a href="Util.html#abstract-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#abstract-instance_method" title="Sass::Util#abstract (method)">#abstract</a>, <a href="Util.html#ap_geq%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ap_geq%3F-instance_method" title="Sass::Util#ap_geq? (method)">#ap_geq?</a>, <a href="Util.html#ap_geq_3%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ap_geq_3%3F-instance_method" title="Sass::Util#ap_geq_3? (method)">#ap_geq_3?</a>, <a href="Util.html#array_minus-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#array_minus-instance_method" title="Sass::Util#array_minus (method)">#array_minus</a>, <a href="Util.html#av_template_class-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#av_template_class-instance_method" title="Sass::Util#av_template_class (method)">#av_template_class</a>, <a href="Util.html#caller_info-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#caller_info-instance_method" title="Sass::Util#caller_info (method)">#caller_info</a>, <a href="Util.html#check_encoding-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#check_encoding-instance_method" title="Sass::Util#check_encoding (method)">#check_encoding</a>, <a href="Util.html#check_range-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#check_range-instance_method" title="Sass::Util#check_range (method)">#check_range</a>, <a href="Util.html#check_sass_encoding-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#check_sass_encoding-instance_method" title="Sass::Util#check_sass_encoding (method)">#check_sass_encoding</a>, <a href="Util.html#destructure-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#destructure-instance_method" title="Sass::Util#destructure (method)">#destructure</a>, <a href="Util.html#enum_cons-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#enum_cons-instance_method" title="Sass::Util#enum_cons (method)">#enum_cons</a>, <a href="Util.html#enum_slice-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#enum_slice-instance_method" title="Sass::Util#enum_slice (method)">#enum_slice</a>, <a href="Util.html#enum_with_index-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#enum_with_index-instance_method" title="Sass::Util#enum_with_index (method)">#enum_with_index</a>, <a href="Util.html#extract%21-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#extract%21-instance_method" title="Sass::Util#extract! (method)">#extract!</a>, <a href="Util.html#extract_values-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#extract_values-instance_method" title="Sass::Util#extract_values (method)">#extract_values</a>, <a href="Util.html#flatten-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#flatten-instance_method" title="Sass::Util#flatten (method)">#flatten</a>, <a href="Util.html#glob-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#glob-instance_method" title="Sass::Util#glob (method)">#glob</a>, <a href="Util.html#group_by_to_a-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#group_by_to_a-instance_method" title="Sass::Util#group_by_to_a (method)">#group_by_to_a</a>, <a href="Util.html#has%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#has%3F-instance_method" title="Sass::Util#has? (method)">#has?</a>, <a href="Util.html#hash_to_a-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#hash_to_a-instance_method" title="Sass::Util#hash_to_a (method)">#hash_to_a</a>, <a href="Util.html#inject_values-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#inject_values-instance_method" title="Sass::Util#inject_values (method)">#inject_values</a>, <a href="Util.html#inspect_obj-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#inspect_obj-instance_method" title="Sass::Util#inspect_obj (method)">#inspect_obj</a>, <a href="Util.html#intersperse-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#intersperse-instance_method" title="Sass::Util#intersperse (method)">#intersperse</a>, <a href="Util.html#ironruby%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ironruby%3F-instance_method" title="Sass::Util#ironruby? (method)">#ironruby?</a>, <a href="Util.html#jruby1_6%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#jruby1_6%3F-instance_method" title="Sass::Util#jruby1_6? (method)">#jruby1_6?</a>, <a href="Util.html#jruby%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#jruby%3F-instance_method" title="Sass::Util#jruby? (method)">#jruby?</a>, <a href="Util.html#jruby_version-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#jruby_version-instance_method" title="Sass::Util#jruby_version (method)">#jruby_version</a>, <a href="Util.html#lcs-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#lcs-instance_method" title="Sass::Util#lcs (method)">#lcs</a>, <a href="Util.html#macruby%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#macruby%3F-instance_method" title="Sass::Util#macruby? (method)">#macruby?</a>, <a href="Util.html#map_hash-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#map_hash-instance_method" title="Sass::Util#map_hash (method)">#map_hash</a>, <a href="Util.html#map_keys-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#map_keys-instance_method" title="Sass::Util#map_keys (method)">#map_keys</a>, <a href="Util.html#map_vals-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#map_vals-instance_method" title="Sass::Util#map_vals (method)">#map_vals</a>, <a href="Util.html#merge_adjacent_strings-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#merge_adjacent_strings-instance_method" title="Sass::Util#merge_adjacent_strings (method)">#merge_adjacent_strings</a>, <a href="Util.html#ord-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ord-instance_method" title="Sass::Util#ord (method)">#ord</a>, <a href="Util.html#paths-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#paths-instance_method" title="Sass::Util#paths (method)">#paths</a>, <a href="Util.html#powerset-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#powerset-instance_method" title="Sass::Util#powerset (method)">#powerset</a>, <a href="Util.html#rails_env-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#rails_env-instance_method" title="Sass::Util#rails_env (method)">#rails_env</a>, <a href="Util.html#rails_root-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#rails_root-instance_method" title="Sass::Util#rails_root (method)">#rails_root</a>, <a href="Util.html#rbx%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#rbx%3F-instance_method" title="Sass::Util#rbx? (method)">#rbx?</a>, <a href="Util.html#restrict-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#restrict-instance_method" title="Sass::Util#restrict (method)">#restrict</a>, <a href="Util.html#ruby1%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ruby1%3F-instance_method" title="Sass::Util#ruby1? (method)">#ruby1?</a>, <a href="Util.html#ruby1_8%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ruby1_8%3F-instance_method" title="Sass::Util#ruby1_8? (method)">#ruby1_8?</a>, <a href="Util.html#ruby1_8_6%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#ruby1_8_6%3F-instance_method" title="Sass::Util#ruby1_8_6? (method)">#ruby1_8_6?</a>, <a href="Util.html#sass_warn-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#sass_warn-instance_method" title="Sass::Util#sass_warn (method)">#sass_warn</a>, <a href="Util.html#scope-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#scope-instance_method" title="Sass::Util#scope (method)">#scope</a>, <a href="Util.html#set_eql%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#set_eql%3F-instance_method" title="Sass::Util#set_eql? (method)">#set_eql?</a>, <a href="Util.html#set_hash-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#set_hash-instance_method" title="Sass::Util#set_hash (method)">#set_hash</a>, <a href="Util.html#silence_sass_warnings-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#silence_sass_warnings-instance_method" title="Sass::Util#silence_sass_warnings (method)">#silence_sass_warnings</a>, <a href="Util.html#silence_warnings-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#silence_warnings-instance_method" title="Sass::Util#silence_warnings (method)">#silence_warnings</a>, <a href="Util.html#strip_string_array-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#strip_string_array-instance_method" title="Sass::Util#strip_string_array (method)">#strip_string_array</a>, <a href="Util.html#subsequence%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#subsequence%3F-instance_method" title="Sass::Util#subsequence? (method)">#subsequence?</a>, <a href="Util.html#substitute-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#substitute-instance_method" title="Sass::Util#substitute (method)">#substitute</a>, <a href="Util.html#to_hash-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#to_hash-instance_method" title="Sass::Util#to_hash (method)">#to_hash</a>, <a href="Util.html#undefined_conversion_error_char-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#undefined_conversion_error_char-instance_method" title="Sass::Util#undefined_conversion_error_char (method)">#undefined_conversion_error_char</a>, <a href="Util.html#version_geq-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#version_geq-instance_method" title="Sass::Util#version_geq (method)">#version_geq</a>, <a href="Util.html#version_gt-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#version_gt-instance_method" title="Sass::Util#version_gt (method)">#version_gt</a>, <a href="Util.html#windows%3F-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#windows%3F-instance_method" title="Sass::Util#windows? (method)">#windows?</a>, <a href="Util.html#with_extracted_values-instance_method" tppabs="http://sass-lang.com/docs/yardoc/Sass/Util.html#with_extracted_values-instance_method" title="Sass::Util#with_extracted_values (method)">#with_extracted_values</a></p>
<div id="constructor_details" class="method_details_list">
  <h2>Constructor Details</h2>
  
    <div class="method_details first">
  <p class="signature first" id="initialize-instance_method">
  
    - (<tt><a href="" title="Sass::Engine (class)">Engine</a></tt>) <strong>initialize</strong>(template, options = {}) 
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>Creates a new Engine. Note that Engine should only be used directly when compiling in-memory Sass code. If you&#8217;re compiling a single Sass file from the filesystem, use <tt><a href="#for_file-class_method" title="Sass::Engine.for_file (method)">Sass::Engine.for_file</a></tt>. If you&#8217;re compiling multiple files from the filesystem, use <tt><a href="Plugin.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Plugin.html" title="Sass::Plugin (module)">Sass::Plugin</a></tt>.</p>

  </div>
</div>
<div class="tags">
  <h3>Parameters:</h3>
<ul class="param">
  
    <li>
      
        <span class='type'>(<tt>String</tt>)</span>
      
      
        <span class='name'>template</span>
      
      
      
        &mdash;
        The Sass template. This template can be encoded using any encoding that can be converted to Unicode. If the template contains an <code>@charset</code> declaration, that overrides the Ruby encoding (see <a href="file.SASS_REFERENCE.html#encodings" tppabs="http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html#encodings" title="the encoding documentation">the encoding documentation</a>)
      
    </li>
  
    <li>
      
        <span class='type'>(<tt>{Symbol =&gt; Object}</tt>)</span>
      
      
        <span class='name'>options</span>
      
      
        <em class="default">(defaults to: <tt>{}</tt>)</em>
      
      
        &mdash;
        An options hash. See <a href="file.SASS_REFERENCE.html#sass_options" tppabs="http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html#sass_options" title="the Sass options documentation">the Sass options documentation</a>.
      
    </li>
  
</ul>

  <h3>See Also:</h3>
  <ul class="see">
    
      <li>{Sass::Engine.for_file}</li>
    
      <li>{Sass::Plugin}</li>
    
  </ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


249
250
251
252</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 249</span>

def initialize(template, options={})
  @options = self.class.normalize_options(options)
  @template = template
end</pre>
    </td>
  </tr>
</table>
</div>
  
</div>

  <div id="instance_attr_details" class="attr_details">
    <h2>Instance Attribute Details</h2>
    
      
      <span id=""></span>
      <span id="options-instance_method"></span>
      <div class="method_details first">
  <p class="signature first" id="options-instance_method">
  
    - (<tt>{Symbol =&gt; Object}</tt>) <strong>options</strong>  <span class="extras">(readonly)</span>
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>The options for the Sass engine. See <a href="file.SASS_REFERENCE.html#sass_options" tppabs="http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html#sass_options" title="the Sass options documentation">the Sass options documentation</a>.</p>

  </div>
</div>
<div class="tags">
  <h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt>{Symbol =&gt; Object}</tt>)</span>
      
      
      
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


230
231
232</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 230</span>

def options
  @options
end</pre>
    </td>
  </tr>
</table>
</div>
    
  </div>


  <div id="class_method_details" class="method_details_list">
    <h2>Class Method Details</h2>
    
    
      <div class="method_details first">
  <p class="signature first" id="for_file-class_method">
  
    + (<tt><a href="" title="Sass::Engine (class)">Sass::Engine</a></tt>) <strong>for_file</strong>(filename, options) 
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>Returns the <tt><a href="" title="Sass::Engine (class)">Sass::Engine</a></tt> for the given file. This is preferable to Sass::Engine.new when reading from a file because it properly sets up the Engine&#8217;s metadata, enables parse-tree caching, and infers the syntax from the filename.</p>

  </div>
</div>
<div class="tags">
  <h3>Parameters:</h3>
<ul class="param">
  
    <li>
      
        <span class='type'>(<tt>String</tt>)</span>
      
      
        <span class='name'>filename</span>
      
      
      
        &mdash;
        The path to the Sass or SCSS file
      
    </li>
  
    <li>
      
        <span class='type'>(<tt>{Symbol =&gt; Object}</tt>)</span>
      
      
        <span class='name'>options</span>
      
      
      
        &mdash;
        The options hash; See <a href="file.SASS_REFERENCE.html#sass_options" tppabs="http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html#sass_options" title="the Sass options documentation">the Sass options documentation</a>.
      
    </li>
  
</ul>
<h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt><a href="" title="Sass::Engine (class)">Sass::Engine</a></tt>)</span>
      
      
      
      
        &mdash;
        The Engine for the given Sass or SCSS file.
      
    </li>
  
</ul>
<h3>Raises:</h3>
<ul class="raise">
  
    <li>
      
        <span class='type'>(<tt><a href="SyntaxError.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/SyntaxError.html" title="Sass::SyntaxError (class)">Sass::SyntaxError</a></tt>)</span>
      
      
      
      
        &mdash;
        if there&#8217;s an error in the document.
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


212
213
214
215
216
217
218
219
220
221
222
223
224</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 212</span>

def self.for_file(filename, options)
  had_syntax = options[:syntax]

  if had_syntax
    # Use what was explicitly specificed
  elsif filename =~ /\.scss$/
    options.merge!(:syntax => :scss)
  elsif filename =~ /\.sass$/
    options.merge!(:syntax => :sass)
  end

  Sass::Engine.new(File.read(filename), options.merge(:filename => filename))
end</pre>
    </td>
  </tr>
</table>
</div>
    
  </div>

  <div id="instance_method_details" class="method_details_list">
    <h2>Instance Method Details</h2>
    
    
      <div class="method_details first">
  <p class="signature first" id="dependencies-instance_method">
  
    - (<tt>[<a href="" title="Sass::Engine (class)">Sass::Engine</a>]</tt>) <strong>dependencies</strong> 
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>Gets a set of all the documents that are (transitive) dependencies of this document, not including the document itself.</p>

  </div>
</div>
<div class="tags">
  <h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt>[<a href="" title="Sass::Engine (class)">Sass::Engine</a>]</tt>)</span>
      
      
      
      
        &mdash;
        The dependency documents.
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


294
295
296
297</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 294</span>

def dependencies
  _dependencies(Set.new, engines = Set.new)
  Sass::Util.array_minus(engines, [self])
end</pre>
    </td>
  </tr>
</table>
</div>
    
      <div class="method_details ">
  <p class="signature " id="render-instance_method">
  
    - (<tt>String</tt>) <strong>render</strong> 
  

  
    <span class="aliases">Also known as:
    <span class="names"><span id='to_css-instance_method'>to_css</span></span>
    </span>
  
</p><div class="docstring">
  <div class="discussion">
    <p>Render the template to CSS.</p>

  </div>
</div>
<div class="tags">
  <h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt>String</tt>)</span>
      
      
      
      
        &mdash;
        The CSS
      
    </li>
  
</ul>
<h3>Raises:</h3>
<ul class="raise">
  
    <li>
      
        <span class='type'>(<tt><a href="SyntaxError.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/SyntaxError.html" title="Sass::SyntaxError (class)">Sass::SyntaxError</a></tt>)</span>
      
      
      
      
        &mdash;
        if there&#8217;s an error in the document
      
    </li>
  
    <li>
      
        <span class='type'>(<tt>Encoding::UndefinedConversionError</tt>)</span>
      
      
      
      
        &mdash;
        if the source encoding cannot be converted to UTF-8
      
    </li>
  
    <li>
      
        <span class='type'>(<tt>ArgumentError</tt>)</span>
      
      
      
      
        &mdash;
        if the document uses an unknown encoding with <code>@charset</code>
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


261
262
263
264</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 261</span>

def render
  return _render unless @options[:quiet]
  Sass::Util.silence_sass_warnings {_render}
end</pre>
    </td>
  </tr>
</table>
</div>
    
      <div class="method_details ">
  <p class="signature " id="source_encoding-instance_method">
  
    - (<tt>Encoding</tt><sup>?</sup>) <strong>source_encoding</strong> 
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>Returns the original encoding of the document, or <code>nil</code> under Ruby 1.8.</p>

  </div>
</div>
<div class="tags">
  <h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt>Encoding</tt>, <tt>nil</tt>)</span>
      
      
      
      
    </li>
  
</ul>
<h3>Raises:</h3>
<ul class="raise">
  
    <li>
      
        <span class='type'>(<tt>Encoding::UndefinedConversionError</tt>)</span>
      
      
      
      
        &mdash;
        if the source encoding cannot be converted to UTF-8
      
    </li>
  
    <li>
      
        <span class='type'>(<tt>ArgumentError</tt>)</span>
      
      
      
      
        &mdash;
        if the document uses an unknown encoding with <code>@charset</code>
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


284
285
286
287</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 284</span>

def source_encoding
  check_encoding!
  @original_encoding
end</pre>
    </td>
  </tr>
</table>
</div>
    
      <div class="method_details ">
  <p class="signature " id="to_tree-instance_method">
  
    - (<tt><a href="Node.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Tree/Node.html" title="Sass::Tree::Node (class)">Sass::Tree::Node</a></tt>) <strong>to_tree</strong> 
  

  
</p><div class="docstring">
  <div class="discussion">
    <p>Parses the document into its parse tree. Memoized.</p>

  </div>
</div>
<div class="tags">
  <h3>Returns:</h3>
<ul class="return">
  
    <li>
      
        <span class='type'>(<tt><a href="Node.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/Tree/Node.html" title="Sass::Tree::Node (class)">Sass::Tree::Node</a></tt>)</span>
      
      
      
      
        &mdash;
        The root of the parse tree.
      
    </li>
  
</ul>
<h3>Raises:</h3>
<ul class="raise">
  
    <li>
      
        <span class='type'>(<tt><a href="SyntaxError.html" tppabs="http://sass-lang.com/docs/yardoc/Sass/SyntaxError.html" title="Sass::SyntaxError (class)">Sass::SyntaxError</a></tt>)</span>
      
      
      
      
        &mdash;
        if there&#8217;s an error in the document
      
    </li>
  
</ul>

</div><table class="source_code">
  <tr>
    <td>
      <pre class="lines">


271
272
273
274
275</pre>
    </td>
    <td>
      <pre class="code"><span class="info file"># File '/var/www/sass-pages/.sass/lib/sass/engine.rb', line 271</span>

def to_tree
  @tree ||= @options[:quiet] ?
    Sass::Util.silence_sass_warnings {_to_tree} :
    _to_tree
end</pre>
    </td>
  </tr>
</table>
</div>
    
  </div>

</div>
    
    <div id="footer">
  Generated on Fri Mar  8 20:33:46 2013 by 
  <a href="javascript:if(confirm(%27http://yardoc.org/  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?%27))window.location=%27http://yardoc.org/%27" tppabs="http://yardoc.org/" title="Yay! A Ruby Documentation Tool">yard</a>
  0.5.3 (ruby-1.8.7).
</div>


  <script type="text/javascript">
  var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
  document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
  </script>
  <script type="text/javascript">
  try {
  var pageTracker = _gat._getTracker("UA-535380-8");
  pageTracker._trackPageview();
  } catch(err) {}</script>


  </body>
</html>